determine the domain of a function